package com.app.core.config;

public class BaseConfig {
    public final static boolean IS_DEBUG = true; // 是否输出log与toasttest
    public final static String PREFERENCES_DEFAULT_NAME = "WL_DFYC_SHAREDPREFERENCES";
    public final static int MAX_HISTORY = 20;
    public final static int MAX_DATA_SIZE = 20;
    public final static String TEXT_COLOR_HEAD = "<font color=";
    public final static String TEXT_COLOR_FOOT = "</font>";
    public final static int FONT_SIZE_NORMAL = 15;
    public final static int FONT_SIZE_BIGGER = 20;
    public final static int FONT_SIZE_BIGGEST = 30;
    public final static String CUSTOM_SERVICE_TEL = "0534-2216111";
    public final static String XML_CITY_NAME = "city.xml";
    public final static String SMS_COUNTRY = "86";  //中国
    public final static int VERSION_B = 2;
    public final static int VERSION_M = 1;
    public final static int VERSION_S = 8;
    //1alpha 2beta 3release
    public final static int VERSION_MOD = 2;
    public final static int VERSION_V = 4;

    public static class Constant {
        public final static int GOODS = 0;
        public final static int CAR = 1;
        public final static String DEFULT_PROVINCE = "山东";
        public final static String DEFULT_CITY = "德州";
    }

    public static class GoodsOrCarsRpc {
        public final static int GOODS = 1;
        public final static int CAR = 2;
    }

    public static class InternetConfig {
        public static final int ACCESS_SUCCESS = 0; // 访问成功
        public static final int ACCESS_ERROR_UNKNOWN = 1; // 访问失败，原因未知
        public static final int ACCESS_ERROR_IO = 2; // 访问失败，IO异常
        public final static String UPDATE_ADDRESS = "http://update.cnxwwl.com:8088/android/version.xml";
        public final static String ADDRESS = "115.28.234.215"; // 服务器地址
        //public final static String ADDRESS = "192.168.31.225"; // 服务器地址
        public final static int PORT = 2002; // 端口号
        public final static int TIMEOUT = 5000; // socket连接超时时间
        public final static int RECONNECT_TIME = 3000;  //断线重连时间，单位毫秒
        public final static int ITEM_PULL_COUNT = 20;       //itempull请求数量
        public final static int ITEM_PULL_NEXT_COUNT = 20;  //itempullnext请求数量
        public final static int SOCKET_PORT = 1301;  //新版本socket端口号

    }

    public static class Request {
        public static final int Login = 2; // 登陆
        public static final int ItemPull = 3;    //第一次拉取数据, 在此之后服务器才会推送新数据
        public static final int ItemPush = 4;   // 发布信息
        public static final int ItemCreated = 5;    //服务器推送的要添加的信息
        public static final int MyItems = 19;        //获取自己发布的历史信息
        public static final int MyLastItems = 11;   //获取自己最后发布的信息(车/货), 最多各1条
        public static final int ItemFinish = 10;    //设置某信息已成交
        public static final int ItemPullByWords = 18;    //按照关键字拉取信息
        public static final int ItemPullByWords2 = 1020;    //与ItemPullByWords完全一致, 仅命令不同
        public static final int ItemDeleted = 19;        //服务器推送的要删掉的信息
        public static final int ItemPullNext = 12;        //服务器推送的要删掉的信息
        public static final int ItemPullNext_None = 122;        //服务器推送的要删掉的信息
        public static final int PullMapXml = 1023;        //服务器推送的要删掉的信息
        public static final int QueryOrder = 1026;
        public static final int AcceptOrder = 1027;
        public static final int ConfirmOrder = 1028;
        public static final int FinishOrder = 1029;
        public static final int ON_ORDER_CREATED = 1030;
        public static final int ON_ORDER_CHANGED = 1031;
        public static final int OrderScoreUpdated = 1032;
        public static final int SetOrderScore = 1033;
        public static final int VerifyUser = 1034;
        public static final int CreateOrder = 1035;
    }

    public static class SharePreferenceKey {
        public static final String ISREMEMBER = "wl_isremember";
        public static final String USERNAME = "wl_username";
        public static final String PASSWORD = "wl_password";
        public static final String ISSOUND = "wl_issound";
        public static final String ISLOGIN = "wl_islogin";
        public static final String NOW_USERNAME = "wl_nowusername";
        public static final String NOW_PASSWORD = "wl_nowpassword";
        public static final String FONT_SIZE = "wl_fontsize";
        public static final String FONT_COLOR = "wl_fontcolor";
        public static final String FONT_SEARCH_COLOR = "wl_fontsearchcolor";
        public static final String ISWULIUCALL = "wl_iswuliucall";
    }

    public static class DbConfig {
        public final static String DB_NAME = "wl_dfyc.db";
        public final static int DB_VERSION = 1;
    }

    public static class MessageCode {
        public static final int ON_GET_HISTORY = 0;
        public static final int ON_SELECT_HISTORY = 1;
        public static final int RELOGIN = 3;      //重新登录
        public static final int ON_PUBLISH_SUCCESS = 4;         //发布成功时
        public static final int ON_CITY_BACK = 6;
        public static final int ON_CHANGE_FONTSIZE = 7;
        public static final int ON_BACK_CITYLIST = 1008;    //回城市列表
        public static final int ON_TITLE_CLICKED = 1009;    //title被点击
        public static final int ON_ORDERDETAILACTIVITY_CLOSE = 2010;
        public static final int SHOW_AD = 2011;
        public static final int DISMISS_AD = 2012;
        public static final int ON_CHANGE_FONT = 2013;
        public static final int ON_CLOSE_INFORMATIONMANAGER = 2014;
        public static final int ON_GETAUTHSTATE = 2015;
        public static final int ON_UPLOADAUTH = 2016;
        public static final int ON_SMS_CALLBACK = 2017;
        public static final int ON_REGISTER_LOGIN = 2018;
        public static final int ON_SELECT_BANK = 2019;
        public static final int ON_BACK = 2020;
        public static final int ON_DELETE_NEWORDER = 2021;
        public static final int ON_STATE_VOICE = 2022;
        public static final int ON_ORDERDETAIL_UPDATE = 2023;
        public static final int ON_NEWORDER_ADD = 2024;
        public static final int ON_CHECK_LOCATION = 2025;
        public static final int ON_SELECT_CITY = 2026;
        public static final int ON_CONNECTMQ = 2027;
        public static final int ON_SELECT_PROVINCE = 2028;
        public static final int ON_SELECT_REGION = 2029;
        public static final int ON_SELECT_REGION_GOODS_FROM = 2030;
        public static final int ON_SELECT_REGION_TRUCK_FROM = 2031;
        public static final int ON_SELECT_REGION_GOODS_TO = 2032;
        public static final int ON_SELECT_REGION_TRUCK_TO = 2033;
        public static final int ON_SELECT_GOODS = 2034;
        public static final int ON_SELECT_UNIT = 2035;
        public static final int ON_SELECT_TRUCKTYPE = 2036;
        public static final int ON_REPUBLISH_GOODS = 2037;
        public static final int ON_REPUBLISH_TRUCK = 2038;
        public static final int ON_CLICKITEM = 2039;
        public static final int ON_DEAL_INFO = 2040;

    }

    public static class URLBank {
                public static final String login = "http://login.cnxwwl.com:1200/login/login";
//        public static final String login = "http://192.168.1.162:1200/login/login";       //刘静帅
//        public static final String login = "http://121.42.137.117:1200/login/login";       //测试服务器
        public static final String gate = "/gate/gate";
    }

    public static class MethodName {
        public static final String login = "login";
        public static final String uploadAuthPhotos = "uploadAuthPhotos";
        public static final String testException = "testException";
        public static final String getGate = "getGate";
        public static final String pullItem = "pullItem";
        public static final String pullItemByCity = "pullItemByCity";
        public static final String pushItem = "pushItem";
        public static final String searchItem = "searchItem";
        public static final String insideResp = "insideResp";
        public static final String addChangeCityLog = "addChangeCityLog";
        public static final String showProtocol = "showProtocol";
        public static final String grabInsideNumber = "grabInsideNumber";
        public static final String searchItemByCity = "searchItemByCity";
        public static final String queryOrders = "queryOrders";
        public static final String acceptOrder = "acceptOrder";
        public static final String loadingTranOrder = "loadingTranOrder";
        public static final String acceptTranOrder = "acceptTranOrder";
        public static final String cancelOrder = "cancelOrder";
        public static final String withdrawList = "withdrawList";
        public static final String rechargeList = "rechargeList";
        public static final String submitWithdraw = "submitWithdraw";
        public static final String newOrderList = "newOrderList";
        public static final String finishOrderList = "finishOrderList";
        public static final String submitOrder2 = "submitOrder2";
        public static final String selectByUsername = "selectByUsername";
        public static final String myPurse = "myPurse";
        public static final String confirmOrder = "confirmOrder";
        public static final String finishOrder = "finishOrder";
        public static final String getMyLastItem = "getMyLastItem";
        public static final String getMyHisItems = "getMyHisItems";
        public static final String getMapXml = "getMapXml";
        public static final String getUserItem = "getUserItem";
        public static final String verifyUser = "verifyUser";
        public static final String getMyItemsHisByType = "getMyItemsHisByType";
        public static final String deleteItem = "deleteItem";
        public static final String createOrder = "createOrder";
        public static final String deleteOrder = "deleteOrder";
        public static final String setOrderScore = "setOrderScore";
        public static final String updateLoginRecord = "updateLoginRecord";
        public static final String getAd = "getAd";
        public static final String getAuthState = "getAuthState";
        public static final String registerUser = "registerUser";
        public static final String getUserMoney = "getUserMoney";
        public static final String getItemCountById = "getItemCountById";
        public static final String carownerStartOrder = "carownerStartOrder";
        public static final String addAppraise = "addAppraise";
        public static final String appraiseList = "appraiseList";
        public static final String addReply = "addReply";
        public static final String getLocation = "getLocation";
        public static final String checkTranOrder = "checkTranOrder";
        public static final String updateLocation = "updateLocation";
        public static final String shipperAcceptOrder = "shipperAcceptOrder";
        public static final String carownerConfirmOrder = "carownerConfirmOrder";
        public static final String pushItemOfAddress = "pushItemOfAddress";
        public static final String insideNumberList = "insideNumberList";
        public static final String myAppraise = "myAppraise";
    }

    public static class Command {
        public static final int ITEM_CREATED = 2101;
        public static final int ITEM_DELETED = 2102;
        public static final int ORDER_CREATED = 2103;
        public static final int ORDER_DELETED = 2104;
        public static final int ORDER_CHANGED = 2105;
        public static final int ORDER_SCORED = 2106;
    }

    public static class MQ {
//        public static final String MQ_IP = "192.168.1.162";
        public static final String MQ_IP = "115.28.187.177";
        public static final int MQ_PORT = 5672;
        public static final String MQ_USERNAME = "dezhou";
        public static final String MQ_PASSWORD = "dezhou";
        public static final String MQ_VH = "/dezhou";
        public static final String MQ_EX = "DEZHOU-ITEM-EXCHANAGE";
        public static final String MQ_GOODS = "android_h_";
        public static final String MQ_TRUCK = "android_t_";
    }
}

